<template>
    <div class="container">
        <div class="input-box">
            <div><i @click="btnBack" class="icon-back el-icon-arrow-left"></i></div>
            <el-input
                    class="input"
                    placeholder="请输入内容"
                    prefix-icon="el-icon-search"
                    v-model="inputText">
            </el-input>
            <div><i class="icon-add el-icon-plus"></i></div>
        </div>
        <div class="option-box1">
            <el-date-picker
                    class="date-picker"
                    v-model="dateTime"
                    type="daterange"
                    start-placeholder="开始日期"
                    end-placeholder="结束日期"
                    value-format="yyyy-MM-dd"
                    >
            </el-date-picker>
            <el-radio-group v-model="tabType">
                <el-radio-button label="支出">支出</el-radio-button>
                <el-radio-button label="收入">收入</el-radio-button>
            </el-radio-group>

        </div>
        <div class="option-box2">
            <el-select class="select-type" v-model="selectValue" placeholder="请选择">
                <el-option
                        v-for="item in options"
                        :key="item.value"
                        :label="item.label"
                        :value="item.value">
                </el-option>
            </el-select>
            <div class="total-text">共计: 1234元</div>
        </div>
    </div>
</template>

<script>
    export default {
        name: "ExpendHead",
        data() {
            return {
                tabType: '支出',
                options: [{
                    value: '1',
                    label: '全部'
                }, {
                    value: '2',
                    label: '行车费'
                }, {
                    value: '3',
                    label: '维修保养费'
                }],
                selectValue: '1',
                inputText: "输入过滤关键字",
                dateTime: []
            }
        },
        methods: {
            btnBack() {
                this.$router.go(-1);
            }
        }
    }
</script>

<style scoped>
    .input-box {
        display: flex;
    }
    .icon-back {
        font-size: 25px;
        line-height: 40px;
        width: 40px;
        text-align: center;
    }
    .input {
        flex: 1;
    }
    .icon-add {
        margin-left: 5px;
        width: 40px;
        line-height: 40px;
        text-align: center;
        color: #fff;
        font-size: 24px;
        border-radius: 10px;
        background-color: #409EFF;
    }
    .option-box1 {
        display: flex;
        margin-top: 5px;
    }
    .option-box1 .date-picker {
        width: 55%;
        border: 0;
    }
    .option-box2 {
        display: flex;
        margin-top: 5px;
    }
    .option-box2>>> .el-input {
        width: 45%;
    }
    .container .option-box2 >>> .el-input__inner {
        border: 0;
    }
    .total-text {
        line-height: 40px;
        text-indent: 1em;
    }
</style>